<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
    <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
    <title>格格恋欢迎你</title>
    <link href="<?php echo base_url();?>css/column/nvzhuang_1.css" type=text/css rel=stylesheet>
    <link href="<?php echo base_url();?>css/column/Album centers.css" type=text/css rel=stylesheet>
    <link href="<?php echo base_url();?>css/column/user-special.css" type=text/css rel=stylesheet>
    <link href="<?php echo base_url();?>css/common/user_header.css" type=text/css rel=stylesheet>
    <LINK href="<?php echo base_url();?>css/common/product_footer.css" type=text/css rel=stylesheet>
    <link href="<?php echo base_url();?>css/common/fans.css" type=text/css rel=stylesheet>
    <link href="<?php echo base_url();?>css/common/admin.css" type=text/css rel=stylesheet>
    
    
    <script src="<?php echo base_url();?>js/jquery/jquery.min.js"></script>
    <script src="<?php echo base_url();?>js/column/blocksit.min.js"></script>
    <script>
        $(document).ready(function() {
            //vendor script
            $('#container').BlocksIt({
                numOfCol:4,
                offsetX: 8,
                offsetY: 8
            });

            //console.log($('#container').height());
        });
    </script>

</head>

<body>
<div class="gege_header">
    <div class="gegelian">
        <?php if($this->session->userdata('member_name')){ ?>
            <div style="">您好! <?php echo $this->session->userdata('member_name');?>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  <a href="<?php echo front_url('login/logout');?>"> 安全退出 </a></div>
        <?php }else{?>
            <div class="gege_tit">您好！欢迎来到格格恋！</div>
            <div class="gege_tit"><a href="<?php echo front_url('login/login');?>">请登录</a></div>
            <div class="gege_tit"><a href="<?php echo front_url('login/register');?>">免费注册</a></div>
        <?php }?>
        <div class="gege_logo">logo</div>
        <div class="gege_collection"><a href="javascript:bookmarksite('格格恋休闲网络', 'http://www.gegelian.com')">收藏格格恋</a></div>
        <div class="gege_login1">新浪微博登录</div>
        <div class="gege_login">QQ登录</div>
    </div>
</div>
<div class="clr"></div>
<div class="user_head">
    <img src="http://img02.taobaocdn.com/tps/i2/T1nUERXgRaXXaCwpjX.png" width="1024" height="45"/>
</div>
<div class="clr"></div>
<div class="user_head">
    <div id="msg1"><p>logo</p></div>
    <div id="msg2"><div class="menu1">
            <div id="nav">
                <ul class="level1">
                    <?php if(! $this->session->userdata('member_name')){ ?>
                        <li class="submenu"><a href="<?php echo base_url();?>login/login">登陆</a></li>
                    <?php }?>
                    <li class="submenu"><a href="#">我要发</a>
                        <ul class="level2">
                            <li><a href="<?php echo base_url();?>column/baby_add">宝贝</a></li>
                            <li><a href="<?php echo base_url();?>column/column_list">专辑</a></li>
                            <li><a href="<?php echo base_url();?>column/life_add">私生活</a></li>
                        </ul>
                    </li>
                    <li class="submenu1"><a href="#">消息</a>
                        <ul class="level2">
                            <li><a href="#">查看评论</a></li>
                            <li><a href="#">查看广播</a></li>
                            <li><a href="<?php echo base_url().'column/focus_list';?>">查看粉丝</a></li>
                        </ul>
                    </li>
                </ul>
            </div>
        </div></div>
</div>
<div class="clr"></div>
<div class="gege_nav">
    <div class="gegelian">
        <h3><a href="<?php echo base_url('index');?>" target="_blank">首页</a></h3>
        <?php
        $baby_class = $this->common->get_list(array('sign'=>'cloth_class'));
        $this->member_id = $this->session->userdata('member_id');
        
        if(!empty($baby_class)){
            foreach($baby_class as $bac => $bav){
                ?>
                <h3><a href="<?php echo base_url().'index/baby_list/'.$bav['id'];?>" target="_blank"><?php echo $bav['name'];?></a></h3>
            <?php }}?>
        <h3><a href="<?php echo base_url('free');?>">免费试用</a></h3>
        <h3 class="gege_forum"><a href="<?php echo base_url('member');?>">格格们</a></h3>
        <h3 class="gege_forum"><a href="<?php echo base_url('index/life_newsl/news_info');?>">新闻资讯</a></h3>
        <h3 class="gege_forum"><a href="<?php echo base_url('index/life_newsl/life_share');?>">私搭广场</a></h3>
        <input type="text" value="女装" onfocus="this.value=''" id="sea"><span class="seach"><b>搜索</b></span>
    </div>

</div>
<div class="clr"></div>

<!-- 放到专辑详情页是多余的 -->
  
<div id="frame">
    <div id="message">
        <?php
            $user = $this->session->userdata('member_name') ? $this->session->userdata('member_name') : '';
            $uid = $this->session->userdata('member_id') ? $this->session->userdata('member_id') : '';
            $focus_num = 0;
            $fans_num = 0;
            if(!empty($mem_info['id'])){
            	$user_id = $mem_info['id'];
            }elseif (!empty($uid)){
            	$user_id = $this->session->userdata('member_id');
            }else{
            	$user_id = '';
            }

            $one_member = $this->member->get_one_list($user_id);
             
            $focus_num_sql = 'select * from focus where focuser = "' . $user_id . '"'; //关注人
            $fans_num_sql  = 'select * from focus where focuseder = "' . $user_id . '"'; //粉丝
            
            $focus_num = $this->db->query($focus_num_sql)->num_rows();
            $fans_num = $this->db->query($fans_num_sql)->num_rows();
        ?>
        <?php if(!empty($one_member)){?>
        <div id="umsg">
            <div id="userlogo">
            <?php if($uid == $user_id && !empty($uid)){?>
                <a href="<?php echo base_url('person/person_data');?>">
            <?php }else{?>    
            	<a href="<?php echo base_url('column/center').'/'.$user_id;?>">
            <?php }?>
                    <img width="80px" height="80px" src="<?php if(!empty($one_member['img'])){echo base_url().'upload/avator/'.$one_member['img'];}else{echo 'http://assets.taobaocdn.com/app/sns/img/default/avatar-60.png';}?>" />
                </a>
            </div>
            <div id="userID">
                <span id="username">
                <?php if($uid == $user_id && !empty($uid)){?>
                <a href="<?php echo base_url('person/person_data');?>">
	            <?php }else{?>    
	            	<a href="<?php echo base_url('column/center').'/'.$user_id;?>">
	            <?php }?>
                <b><?php echo $one_member['name'];?></b>
                </a>
                </span>
                <div class="clr1"></div>
                <span class="from">来自：<?php echo $one_member['address'];?></span>
                <div class="clr1"></div>
                <span class="from">用户等级：<img src="http://a.tbcdn.cn/sys/common/icon/rank_s/b_red_4.gif"></span>
            </div>
        </div>
        <?php }?>
        <div id="bumsg">
            <div id="umsg1">
                <div class="etc">
                    <span class="from"><b>粉丝</b></span>
                    <div class="clr1"></div>
                    <span class="from1"><a href="<?php echo base_url();?>column/focus_list/<?php $user_id;?>"><?php echo $fans_num;?></a></span>
                </div>
                <div class="etc1">
                    <span class="from"><b>关注</b></span>
                    <div class="clr1"></div>
                    <span class="from1"><a href="<?php echo base_url();?>column/focus_list/<?php $user_id;?>"><?php echo $focus_num;?></a></span>
                </div>
            </div>
            <div class="clr1"></div>
            <span id="honor">去勋章馆>></span>

        </div>

        <div id="umsg2">
            <span id="friend"><b>TA跟你有共同的好友</b></span>
            <div class="clr1"></div>
            <div id="friend1">
                <div class="friendimage">
                    <img src="http://img02.taobaocdn.com/bao/uploaded/i2/T13d5FXlJmXXb1upjX.jpg_40x40.jpg" width="40" height="40">
                </div>
                <div class="friendname"><b>不靠谱姑娘哟</b></div>
            </div>
            <div class="clr1"></div>
            <div id="friend1">
                <div class="friendimage">
                    <img src="http://img01.taobaocdn.com/bao/uploaded/i1/T1TaOMXe4pXXb1upjX.jpg_40x40.jpg" width="40" height="40">
                </div>
                <div class="friendname"><b>slt13738111385</b></div>
            </div>
        </div>
    </div>

</div>

<div class="clr1"></div>

<div id="frame1">
    <div id="message1">
        <h3 class="classify1" onmouseover="this.className='classify1'" onmouseout="this.className='content1'"><a href="<?php echo base_url();?>column/center/<?php echo $user_id;?>">个人首页</a></h3>
        <h3 onmouseover="this.className='h31'" onmouseout="this.className='content1'"><a href="<?php echo base_url();?>column/baby_list/<?php echo $user_id;?>">宝贝</a></h3>
        <h3 onmouseover="this.className='h31'" onmouseout="this.className='content1'"><a href="<?php echo base_url();?>column/column_list/<?php echo $user_id;?>">专辑</a></h3>
        <h3 onmouseover="this.className='h31'" onmouseout="this.className='content1'" ><a href="<?php echo base_url().'index/life_newsl/life_share/'.$user_id;;?>">生活私搭</a></h3>
    </div>
</div>
<div class="clr1"></div>

